package gameEngine.experiments;

import gameEngine.game.Game;

import java.util.ArrayList;

import org.apache.log4j.Logger;
/**
 * runs all games one by one
 * @author alon
 *
 */
public class SimpleExperimentImpl implements Experiment {

	private ArrayList<Game> games=new ArrayList<Game>();
	Logger log=Logger.getLogger(this.getClass());
	
	public void run() {	
		log.info("Experiment started");
		int listSize=games.size();
		for(int i=0;i<listSize;i++){
			log.info("game "+i+" started");
			games.get(i).play();
		}
	}
	
	public void addGame(Game game){
		games.add(game);
	}

}
